#ifndef TELEMENT_H
#define TELEMENT_H

template<class TContent>
class TElement {
private:
	//casuses "ambigious class" so commented
	//friend class List;
	TContent* content;
	TElement* next;
	TElement* prev;

public:
	TElement(TContent* newContent, TElement* newNext, TElement* newPrev) :
			content(newContent), next(newNext), prev(newPrev) {
		next = newNext;
		prev = newPrev;
		content = newContent;
	}
	virtual ~TElement() {
	}
	void setPrev(TElement* newEl) {
		this->prev = newEl;
	}
	void setNext(TElement* newEl) {
		this->next = newEl;
	}
	TElement* getPrev(TElement*) {
		return prev;
	}
	TElement* getNext(TElement*) {
		return next;
	}
	TContent* getContent() {
		return content;
	}
};

#endif
